diff --git a/src/ast.hpp b/src/ast.hpp index 08984b6dfe..c77fdf1226 100644 --- a/src/ast.hpp +++ b/src/ast.hpp @@ -481,18 +481,6 @@ namespace Sass { ATTACH_OPERATIONS() }; - ///////////////////////////////////////////////////////// - // Nested declaration sets (i.e., namespaced properties). - ///////////////////////////////////////////////////////// - class Propset : public Has_Block { - ADD_PROPERTY(String*, property_fragment) - public: - Propset(ParserState pstate, String* pf, Block* b = 0) - : Has_Block(pstate, b), property_fragment_(pf) - { } - ATTACH_OPERATIONS() - }; - ///////////////// // Bubble. ///////////////// diff --git a/src/ast_factory.hpp b/src/ast_factory.hpp index 1492fcc51f..8e2a5e2b5e 100644 --- a/src/ast_factory.hpp +++ b/src/ast_factory.hpp @@ -13,7 +13,6 @@ namespace Sass { // statements Block* new_Block(std::string p, size_t l, size_t s = 0, bool r = false); Ruleset* new_Ruleset(std::string p, size_t l, Selector* s, Block* b); - Propset* new_Propset(std::string p, size_t l, String* pf, Block* b); Supports_Query* new_Supports_Query(std::string p, size_t l, Supports_Query* f, Block* b); Media_Query* new_Media_Query(std::string p, size_t l, List* q, Block* b); At_Root_Block* new_At_Root_Block(std::string p, size_t l, Selector* sel, Block* b); diff --git a/src/ast_fwd_decl.hpp b/src/ast_fwd_decl.hpp index d19e076d89..f30e9db63e 100644 --- a/src/ast_fwd_decl.hpp +++ b/src/ast_fwd_decl.hpp @@ -11,7 +11,6 @@ namespace Sass { class Statement; class Block; class Ruleset; - class Propset; class Bubble; class Trace; class Media_Block; diff --git a/src/cssize.hpp b/src/cssize.hpp index ee6abd1ad4..87539992b1 100644 --- a/src/cssize.hpp +++ b/src/cssize.hpp @@ -29,7 +29,6 @@ namespace Sass { Statement* operator()(Block*); Statement* operator()(Ruleset*); - // Statement* operator()(Propset*); // Statement* operator()(Bubble*); Statement* operator()(Media_Block*); Statement* operator()(Supports_Block*); diff --git a/src/debugger.hpp b/src/debugger.hpp index 7b6db0cfdb..4216476625 100644 --- a/src/debugger.hpp +++ b/src/debugger.hpp @@ -151,13 +151,6 @@ inline void debug_ast(AST_Node* node, std::string ind, Env* env) std::cerr << (selector->has_line_feed() ? " [line-feed]": " -"); std::cerr << " <" << prettyprint(selector->pstate().token.ws_before()) << ">" << std::endl; for(auto i : selector->elements()) { debug_ast(i, ind + " ", env); } - } else if (dynamic_cast(node)) { - Propset* selector = dynamic_cast(node); - std::cerr << ind << "Propset " << selector; - std::cerr << " (" << pstate_source_position(node) << ")"; - std::cerr << " <" << dynamic_cast(selector->property_fragment())->value() << ">"; - std::cerr << " " << selector->tabs() << std::endl; - if (selector->block()) for(auto i : selector->block()->elements()) { debug_ast(i, ind + " ", env); } } else if (dynamic_cast(node)) { Wrapped_Selector* selector = dynamic_cast(node); std::cerr << ind << "Wrapped_Selector " << selector; diff --git a/src/expand.cpp b/src/expand.cpp index 85859eeb01..1935a22d4e 100644 --- a/src/expand.cpp +++ b/src/expand.cpp @@ -153,53 +153,6 @@ namespace Sass { return rr; } - // this is not properly implemented - // mixes string_schema and statement - Statement* Expand::operator()(Propset* p) - { - String* fragment = dynamic_cast(p->property_fragment()->perform(&eval)); - Propset* prop = SASS_MEMORY_NEW(ctx.mem, Propset, - p->pstate(), - fragment, - p->block()->perform(this)->block()); - prop->tabs(p->tabs()); - return prop; - - - property_stack.push_back(p->property_fragment()); - Block* expanded_block = p->block()->perform(this)->block(); - for (size_t i = 0, L = expanded_block->length(); i < L; ++i) { - Statement* stm = (*expanded_block)[i]; - if (Declaration* dec = static_cast(stm)) { - // dec = SASS_MEMORY_NEW(ctx.mem, Declaration, *dec); - String_Schema* combined_prop = SASS_MEMORY_NEW(ctx.mem, String_Schema, p->pstate()); - if (!property_stack.empty()) { - *combined_prop << property_stack.back()->perform(&eval); - *combined_prop << SASS_MEMORY_NEW(ctx.mem, String_Quoted, p->pstate(), "-"); - if (dec->property()) { - // we cannot directly add block (from dec->property()) to string schema (combined_prop) - *combined_prop << SASS_MEMORY_NEW(ctx.mem, String_Quoted, dec->pstate(), dec->property()->to_string()); - } - } - else { - *combined_prop << dec->property(); - } - dec->property(combined_prop); - *block_stack.back() << dec; - } - else if (typeid(*stm) == typeid(Comment)) { - // drop comments in propsets - } - else { - error("contents of namespaced properties must result in style declarations only", stm->pstate(), backtrace()); - } - } - - property_stack.pop_back(); - - return 0; - } - Statement* Expand::operator()(Supports_Block* f) { Expression* condition = f->condition()->perform(&eval); diff --git a/src/expand.hpp b/src/expand.hpp index b787193c6d..5acbd4d4a6 100644 --- a/src/expand.hpp +++ b/src/expand.hpp @@ -48,7 +48,6 @@ namespace Sass { Statement* operator()(Block*); Statement* operator()(Ruleset*); - Statement* operator()(Propset*); Statement* operator()(Media_Block*); Statement* operator()(Supports_Block*); Statement* operator()(At_Root_Block*); diff --git a/src/inspect.cpp b/src/inspect.cpp index ed14e2cf48..bbdbbba2ac 100644 --- a/src/inspect.cpp +++ b/src/inspect.cpp @@ -51,13 +51,6 @@ namespace Sass { if (rule->block()) rule->block()->perform(this); } - void Inspect::operator()(Propset* propset) - { - propset->property_fragment()->perform(this); - append_colon_separator(); - propset->block()->perform(this); - } - void Inspect::operator()(Bubble* bubble) { append_indentation(); diff --git a/src/inspect.hpp b/src/inspect.hpp index fdbd96e5bf..8a4ed3c1ab 100644 --- a/src/inspect.hpp +++ b/src/inspect.hpp @@ -23,7 +23,6 @@ namespace Sass { // statements virtual void operator()(Block*); virtual void operator()(Ruleset*); - virtual void operator()(Propset*); virtual void operator()(Bubble*); virtual void operator()(Supports_Block*); virtual void operator()(Media_Block*); diff --git a/src/operation.hpp b/src/operation.hpp index c22302fe64..8103d22604 100644 --- a/src/operation.hpp +++ b/src/operation.hpp @@ -13,7 +13,6 @@ namespace Sass { // statements virtual T operator()(Block* x) = 0; virtual T operator()(Ruleset* x) = 0; - virtual T operator()(Propset* x) = 0; virtual T operator()(Bubble* x) = 0; virtual T operator()(Trace* x) = 0; virtual T operator()(Supports_Block* x) = 0; @@ -95,7 +94,6 @@ namespace Sass { // statements T operator()(Block* x) { return static_cast(this)->fallback(x); } T operator()(Ruleset* x) { return static_cast(this)->fallback(x); } - T operator()(Propset* x) { return static_cast(this)->fallback(x); } T operator()(Bubble* x) { return static_cast(this)->fallback(x); } T operator()(Trace* x) { return static_cast(this)->fallback(x); } T operator()(Supports_Block* x) { return static_cast(this)->fallback(x); } diff --git a/src/output.hpp b/src/output.hpp index a6bad52f1d..9174c74d91 100644 --- a/src/output.hpp +++ b/src/output.hpp @@ -35,7 +35,6 @@ namespace Sass { virtual void operator()(Map*); virtual void operator()(Ruleset*); - // virtual void operator()(Propset*); virtual void operator()(Supports_Block*); virtual void operator()(Media_Block*); virtual void operator()(Directive*); diff --git a/src/parser.hpp b/src/parser.hpp index 215c8f8ecc..9fa86faae5 100644 --- a/src/parser.hpp +++ b/src/parser.hpp @@ -236,7 +236,6 @@ namespace Sass { Arguments* parse_arguments(); Argument* parse_argument(); Assignment* parse_assignment(); - // Propset* parse_propset(); Ruleset* parse_ruleset(Lookahead lookahead, bool is_root = false); Selector_Schema* parse_selector_schema(const char* end_of_selector); Selector_List* parse_selector_list(bool at_root = false);