aboutsummaryrefslogtreecommitdiff
path: root/src/include
diff options
context:
space:
mode:
authordos-reis <gdr@axiomatics.org>2014-08-31 16:53:26 +0000
committerdos-reis <gdr@axiomatics.org>2014-08-31 16:53:26 +0000
commit0e93235b14a64463aa127a64b0a867ce48885ce2 (patch)
tree4c0a3707c63c198c12052de6db433aca36e95ea8 /src/include
parente88dc9861a1d7ae4ca3fca1f5ef14d46f7190812 (diff)
downloadopen-axiom-0e93235b14a64463aa127a64b0a867ce48885ce2.tar.gz
Rename BasicString to InternedString
Diffstat (limited to 'src/include')
-rw-r--r--src/include/vm.H16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/include/vm.H b/src/include/vm.H
index 6a3dc872..d321835f 100644
--- a/src/include/vm.H
+++ b/src/include/vm.H
@@ -191,7 +191,7 @@ namespace OpenAxiom {
// ------------
// -- String --
// ------------
- using String = BasicString;
+ using String = InternedString;
constexpr ValueBits str_tag = 0x4;
@@ -199,16 +199,16 @@ namespace OpenAxiom {
return (ValueBits(v) & 0x7) == str_tag;
}
- inline BasicString to_string(Value v) {
- return reinterpret_cast<BasicString>
+ inline InternedString to_string(Value v) {
+ return reinterpret_cast<InternedString>
(ValueBits(v) & ~ValueBits(0x7));
}
- inline Value from_string(BasicString s) {
+ inline Value from_string(InternedString s) {
return Value(ValueBits(s) | str_tag);
}
- inline BasicString to_string_if_can(Value v) {
+ inline InternedString to_string_if_can(Value v) {
return is_string(v) ? to_string(v) : nullptr;
}
@@ -353,12 +353,12 @@ namespace OpenAxiom {
// -- Scope --
// -----------
struct Scope : Dynamic, private std::map<Symbol*, Value> {
- explicit Scope(BasicString n) : id(n) { }
- BasicString name() const { return id; }
+ explicit Scope(InternedString n) : id(n) { }
+ InternedString name() const { return id; }
Value* lookup(Symbol*) const;
Value* define(Symbol*, Value);
private:
- const BasicString id;
+ const InternedString id;
};
// --------------