diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2015-07-28 16:38:37 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2015-07-28 16:38:37 -0700 |
commit | 1f59be846a68a5a4ec456b4104a94e421d135cf1 (patch) | |
tree | e85bf0dcc344b906b8cbf47da43a5e5d2fa9db81 /013literal_string.cc | |
parent | 86d99645dcd8ab83a68f10c30d8321d353ae93ac (diff) | |
download | mu-1f59be846a68a5a4ec456b4104a94e421d135cf1.tar.gz |
1876
Diffstat (limited to '013literal_string.cc')
-rw-r--r-- | 013literal_string.cc | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/013literal_string.cc b/013literal_string.cc index 29a185b2..8054d60f 100644 --- a/013literal_string.cc +++ b/013literal_string.cc @@ -113,19 +113,18 @@ void slurp_quoted_comment_aware(istream& in, ostringstream& out) { out.clear(); } -:(after "reagent::reagent(string s)") -//? cout << s.at(0) << '\n'; //? 1 - if (s.at(0) == '[') { - assert(*s.rbegin() == ']'); - // delete [] delimiters - s.erase(0, 1); - s.erase(SIZE(s)-1); - name = s; - types.push_back(0); - properties.push_back(pair<string, vector<string> >(name, vector<string>())); - properties.back().second.push_back("literal-string"); - return; - } +:(after "Parsing reagent(string s)") +if (s.at(0) == '[') { + assert(*s.rbegin() == ']'); + // delete [] delimiters + s.erase(0, 1); + s.erase(SIZE(s)-1); + name = s; + types.push_back(0); + properties.push_back(pair<string, vector<string> >(name, vector<string>())); + properties.back().second.push_back("literal-string"); + return; +} //: Two tweaks to printing literal strings compared to other reagents: //: a) Don't print the string twice in the representation, just put '_' in |