]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
Fix string templates
authorLuca Bruno <luca.bruno@immobiliare.it>
Mon, 7 Jul 2014 07:57:08 +0000 (09:57 +0200)
committerRico Tzschichholz <ricotz@ubuntu.com>
Mon, 11 Mar 2019 12:52:38 +0000 (13:52 +0100)
vala/valacodetransformer.vala

index c2c84a5d10ef7d62dca0187e728304ef907512aa..70b9aa17bce4a83fc29be61a8edb9a279b4d9a01 100644 (file)
@@ -295,7 +295,7 @@ public class Vala.CodeTransformer : CodeVisitor {
        }
 
        public Expression stringify (Expression expr) {
-               if (expr.value_type.data_type != null && expr.value_type.data_type.is_subtype_of (context.analyzer.string_type.data_type)) {
+               if (expr.value_type != null && expr.value_type.data_type != null && expr.value_type.data_type.is_subtype_of (context.analyzer.string_type.data_type)) {
                        return expr;
                } else {
                        return expression (@"%?.to_string ()", {expr});