Sha256: 811a0b532e8de62a3d659f2eda7ca4f654e22d1132c0913431e5eb5e2cf6b0b3
Contents?: true
Size: 784 Bytes
Versions: 3
Compression:
Stored size: 784 Bytes
Contents
module GirFFI module InfoExt # Extension module provinding a #safe_name method suitable for types. module SafeConstantName def safe_name name.tr('-', '_').gsub(/^./) do |char| case char when "_" "Private___" else char.upcase end end end end end end GObjectIntrospection::ICallbackInfo.send :include, GirFFI::InfoExt::SafeConstantName GObjectIntrospection::IConstantInfo.send :include, GirFFI::InfoExt::SafeConstantName GObjectIntrospection::IRegisteredTypeInfo.send :include, GirFFI::InfoExt::SafeConstantName GObjectIntrospection::ISignalInfo.send :include, GirFFI::InfoExt::SafeConstantName GObjectIntrospection::IVFuncInfo.send :include, GirFFI::InfoExt::SafeConstantName
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
gir_ffi-0.7.7 | lib/gir_ffi/info_ext/safe_constant_name.rb |
gir_ffi-0.7.6 | lib/gir_ffi/info_ext/safe_constant_name.rb |
gir_ffi-0.7.5 | lib/gir_ffi/info_ext/safe_constant_name.rb |