Sha256: cce69187cd4ea99fafc47f15b07d5d35aad9b6e14581aeeaeffa01a50da62e64

Contents?: true

Size: 744 Bytes

Versions: 8

Compression:

Stored size: 744 Bytes

Contents

#ifndef SASS_ERROR_HANDLING
#include "error_handling.hpp"
#endif

#include "backtrace.hpp"
#include "prelexer.hpp"

namespace Sass {

  Sass_Error::Sass_Error(Type type, string path, Position position, string message)
  : type(type), path(path), position(position), message(message)
  { }

  void error(string msg, string path, Position position)
  { throw Sass_Error(Sass_Error::syntax, path, position, msg); }

  void error(string msg, string path, Position position, Backtrace* bt)
  {
    if (!path.empty() && Prelexer::string_constant(path.c_str()))
      path = path.substr(1, path.size() - 1);

    Backtrace top(bt, path, position, "");
    msg += top.to_string();

    throw Sass_Error(Sass_Error::syntax, path, position, msg);
  }

}

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
sassc-0.0.9 ext/libsass/error_handling.cpp
sassc-0.0.8 ext/libsass/error_handling.cpp
sassc-0.0.7 ext/libsass/error_handling.cpp
sassc-0.0.6 ext/libsass/error_handling.cpp
sassc-0.0.5 ext/libsass/error_handling.cpp
sassc-0.0.4 ext/libsass/error_handling.cpp
sassc-0.0.2 ext/libsass/error_handling.cpp
sassc-0.0.1 ext/libsass/error_handling.cpp