aboutsummaryrefslogtreecommitdiffstats
path: root/lib/erb.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/erb.rb')
-rw-r--r--lib/erb.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/erb.rb b/lib/erb.rb
index 2c7e203923..c6e9129120 100644
--- a/lib/erb.rb
+++ b/lib/erb.rb
@@ -518,6 +518,7 @@ class ERB
def compile(s)
out = Buffer.new(self)
+ out.push("# -*- coding: #{s.encoding} -*-")
content = ''
scanner = make_scanner(s)