From 82afdd42e262f0d34139a4fece094c4e90e45d9d Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Fri, 14 Jan 2011 05:37:12 +0000 Subject: [PATCH] The type of a string slice is the type of the string being sliced. From-SVN: r168775 --- gcc/go/gofrontend/expressions.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/go/gofrontend/expressions.cc b/gcc/go/gofrontend/expressions.cc index 550d1aea0ab..a11e3d6fa17 100644 --- a/gcc/go/gofrontend/expressions.cc +++ b/gcc/go/gofrontend/expressions.cc @@ -9541,7 +9541,7 @@ String_index_expression::do_type() if (this->end_ == NULL) return Type::lookup_integer_type("uint8"); else - return Type::make_string_type(); + return this->string_->type(); } // Determine the type of a string index.