summaryrefslogtreecommitdiffstats
path: root/parse.h
diff options
context:
space:
mode:
authorddomingo <ddomingo@redhat.com>2008-10-13 14:38:03 +1000
committerddomingo <ddomingo@redhat.com>2008-10-13 14:38:03 +1000
commitf4e4014f97627cfd36429d1c5b8e65373a837875 (patch)
treea36ae1581270ca034e211e67a8ad45e4aa6a25d7 /parse.h
parent74939defa679347fdd0b32d804b24b9976cb7cf3 (diff)
parent180b066c1d27320c1d706e35f56c8dc165d89583 (diff)
downloadsystemtap-steved-f4e4014f97627cfd36429d1c5b8e65373a837875.tar.gz
systemtap-steved-f4e4014f97627cfd36429d1c5b8e65373a837875.tar.xz
systemtap-steved-f4e4014f97627cfd36429d1c5b8e65373a837875.zip
Merge branch 'master' of ssh://sources.redhat.com/git/systemtap
Diffstat (limited to 'parse.h')
-rw-r--r--parse.h10
1 files changed, 7 insertions, 3 deletions
diff --git a/parse.h b/parse.h
index cf31f4f8..2e2b656f 100644
--- a/parse.h
+++ b/parse.h
@@ -18,11 +18,14 @@
#include <stdexcept>
#include <stdint.h>
+struct stapfile;
+
struct source_loc
{
std::string file;
unsigned line;
unsigned column;
+ stapfile* stap_file;
};
std::ostream& operator << (std::ostream& o, const source_loc& loc);
@@ -71,6 +74,8 @@ class lexer
public:
token* scan (bool wildcard=false);
lexer (std::istream&, const std::string&, systemtap_session&);
+ std::string get_input_contents ();
+ void set_current_file (stapfile* f);
private:
int input_get ();
@@ -79,16 +84,15 @@ private:
int input_peek (unsigned n=0);
std::istream& input;
std::string input_name;
- std::vector<char> input_contents;
+ std::string input_contents;
int input_pointer; // index into input_contents
unsigned cursor_suspend_count;
unsigned cursor_line;
unsigned cursor_column;
systemtap_session& session;
+ stapfile* current_file;
};
-
-struct stapfile;
struct probe;
struct probe_alias;
struct vardecl;