id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 8564,Variable hiding errors within nested let blocks in Phoenix,miremare@…,Thomas Heller,"I encounter errors when using nested let blocks in Phoenix whenever an ""inner"" local variable hides an ""outer"" local variable. The ""Visibility"" example from the documentation at http://www.boost.org/doc/libs/1_53_0/libs/phoenix/doc/html/phoenix/modules/scope/let.html also fails. Here is that ""Visibility"" example as a standalone module which fails: {{{ #include #include namespace phoenix = boost::phoenix; using namespace phoenix::local_names; int main(int argc, char *argv[]) { phoenix::let(_x = 1, _y = "", World"") [ phoenix::let(_x = ""Hello"") // hides the outer _x [ std::cout << _x << _y // prints ""Hello, World"" ] ](); return 0; } }}} The errors I receive from GCC 4.7.2, GCC 4.8 snapshot, and Clang 3.2, with any of Boost 1.49, 1.53, or trunk, begin as follows: GCC: ""error: function returning an array"" Clang: ""error: function cannot return array type 'result_type' (aka 'char [6]')"" Another failing example provided in Eric Niebler's Stack Overflow answer [http://stackoverflow.com/questions/16408770/variable-hiding-within-nested-let-blocks-in-boost-phoenix here] is: {{{ int y = 0; int x = (phoenix::let(_a = 1, _b = 2)[phoenix::let(_b = 3)[ _a ]])(y); }}} ...which contrasts with the following example; which does compile: {{{ int y = 0; int x = (phoenix::let(_a = 1, _b = 2)[phoenix::let(_b = _1)[ _a ]])(y); }}} ",Bugs,new,To Be Determined,phoenix,Boost 1.53.0,Problem,,,