ValueSymbolTable's mutators are private?

Hello,

Why are ValueSymbolTable's mutators all private? I can't seem to find a way to
add a symbol to the table without using one of them. It looks like a bug to me
since there is no way to use it otherwise.

--Sam

The mutators are things like Value::setName()

-Chris

Hi Chris,

I was thinking that CreateValueName() was the way to add a symbol to a symbol
table. Perhaps I'm thinking about this wrong. Here's what I've got:

I've got a string generated by the parser which is constant. I need to add it
to the symbol table so that, on starting the second pass of my compiler, I can
dump all of the string constants to be generated as code. I have a name, a type
(ConstantStruct since the length is stored internally to the structure), and no
place to put it. I thought that since the Module created by my compiler has a
symbol table, I could generate it as a global. I already have a reverse-lookup
StringMap allocated to get the name on the second pass. Should I just make
another StringMap for all of my variable names and declared constants? That
seems to me what a symbol table is used for though.

--Sam

Solved on IRC. GlobalVariable can also be a constant if you specify a flag in
its constructor.