Skip to content

Commit 9e1605d

Browse files
committed
Simplify opstat and remove unused variable.
1 parent f6524f6 commit 9e1605d

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

src/compiler/codestat.cc

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,11 @@
2525
class opstat
2626
{
2727
private:
28-
std::vector<codew> &code;
2928
std::map<enum tokens, int> c1;
3029
std::map<std::pair<enum tokens, enum tokens>, int> c2;
3130
std::map<std::pair<enum tokens, int>, int> c3;
3231
public:
33-
opstat(std::vector<codew> &code):
34-
code(code)
32+
opstat(const std::vector<codew> &code)
3533
{
3634
enum tokens old = TOK_LAST_TOKEN;
3735
for(auto &c: code)

0 commit comments

Comments
 (0)