mirror of
https://github.com/ThrowTheSwitch/CMock.git
synced 2026-09-14 06:09:58 +00:00
Remove support for versions of Ruby before 2.0 (as Rubylang doesn’t even support them anymore)
This commit is contained in:
@@ -13,9 +13,6 @@
|
||||
"cmock_generator_utils",
|
||||
"cmock_unityhelper_parser"].each {|req| require "#{File.expand_path(File.dirname(__FILE__))}/#{req}"}
|
||||
|
||||
|
||||
$QUICK_RUBY_VERSION = RUBY_VERSION.split('.').inject(0){|vv,v| vv * 100 + v.to_i }
|
||||
|
||||
class CMock
|
||||
|
||||
def initialize(options=nil)
|
||||
|
||||
@@ -48,7 +48,7 @@ class CMockHeaderParser
|
||||
def import_source(source)
|
||||
|
||||
# let's clean up the encoding in case they've done anything weird with the characters we might find
|
||||
source = source.force_encoding("ISO-8859-1").encode("utf-8", :replace => nil) if ($QUICK_RUBY_VERSION > 10900)
|
||||
source = source.force_encoding("ISO-8859-1").encode("utf-8", :replace => nil)
|
||||
|
||||
# void must be void for cmock _ExpectAndReturn calls to process properly, not some weird typedef which equates to void
|
||||
# to a certain extent, this action assumes we're chewing on pre-processed header files, otherwise we'll most likely just get stuff from @treat_as_void
|
||||
|
||||
Reference in New Issue
Block a user