summaryrefslogtreecommitdiff
path: root/src/lexer-source.cc
diff options
context:
space:
mode:
authorSam Clegg <sbc@chromium.org>2017-12-02 15:18:55 -0800
committerGitHub <noreply@github.com>2017-12-02 15:18:55 -0800
commitb0d76dac6eb3e08ce14ada96cffb747356c95247 (patch)
tree939cc3222acc3421f9794842caaeac26c8e6126a /src/lexer-source.cc
parent1d5f578380504c40710c56d0c56ed3059605633d (diff)
downloadwabt-b0d76dac6eb3e08ce14ada96cffb747356c95247.tar.gz
wabt-b0d76dac6eb3e08ce14ada96cffb747356c95247.tar.bz2
wabt-b0d76dac6eb3e08ce14ada96cffb747356c95247.zip
Make more use of string_view over 'const char *' (#684)
Diffstat (limited to 'src/lexer-source.cc')
-rw-r--r--src/lexer-source.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lexer-source.cc b/src/lexer-source.cc
index 8a455015..1d59dd9c 100644
--- a/src/lexer-source.cc
+++ b/src/lexer-source.cc
@@ -20,9 +20,9 @@
namespace wabt {
-LexerSourceFile::LexerSourceFile(const std::string& filename)
+LexerSourceFile::LexerSourceFile(string_view filename)
: filename_(filename) {
- file_ = fopen(filename.c_str(), "rb");
+ file_ = fopen(filename_.c_str(), "rb");
}
LexerSourceFile::~LexerSourceFile() {