Fix conversion sequence from QByteArray to const char*.
Fri Jul 24 15:32:23 CEST 2009 Tobias Rautenkranz <tobias@rautenkranz.ch>
* Fix conversion sequence from QByteArray to const char*.
hunk ./src/overload-resolution.lisp 424
+(defun conversion-operator-name (to-type)
+ (concatenate 'string
+ "operator "
+ (if (class-p to-type)
+ (name (get-class to-type))
+ (if (pointer-p to-type)
+ ;; Insert a space before the #\*
+ (let ((name (name to-type)))
+ (concatenate 'string
+ (subseq name 0 (1- (length name)))
+ " *"))
+ (name to-type)))))
+
+(defun coerce-to-type (object method)
+ (pointer-call method (pointer object)))
+ [_$_]
hunk ./src/overload-resolution.lisp 443
- (format nil "operator ~A" [_$_]
- (if (class-p type)
- (name (get-class type))
- (name type))))))
+ (conversion-operator-name type))))
hunk ./src/overload-resolution.lisp 449
- (make-match 'user-conversion
- (lispify (name method) :cxx))))))
+ (if (pointer-p type)
+ (make-match 'user-conversion
+ 'coerce-to-type
+ method)
+ (make-match 'user-conversion
+ (lispify (name method) :cxx)))))))