xot 0.1.22 → 0.1.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: eabd6145d88568b824890e37239195d443c6f0f0d45d8aac09aefbf5950307dc
4
- data.tar.gz: 02775f8af00f140f99b64a7d03b204e78046548bb81c86b062bf26f9bdef5de3
3
+ metadata.gz: 7437d6a467a8e9ef5223ee67df2651e1526e9cabd02960ec854174d76912f840
4
+ data.tar.gz: 2a1147f112de9f7d1f053702d8d80a402d82106a4b973c0bc5742263892ccb95
5
5
  SHA512:
6
- metadata.gz: 0e53581d9a9ffc5aad90afe7fbe45a1460119b9de0e67a819da1351bd856585c29345f5d925a3fd5ec12853fecd2509173a6aa1a12fbf6d91225548348d603c9
7
- data.tar.gz: a7d4934ff11e7d730611f35829a4033ac56bf31eb76adeb96ddc323b2074ebb5ce15e9959a62d78207704ef3537ca0148f83e1f1e364f2337e91fcf174564dfd
6
+ metadata.gz: b1db68794dd51ab98a29d43bfb433c580478cf2ac33e534188901446bafdd71047a889e50a0dbb686b10ffc0f8e85e9a360936eec9e3c46ee81b8c14ce5ee641
7
+ data.tar.gz: aed8163dd738c2871fb2679f16f4d11f6904d3cdc62f21939b26df361ade5f4891771b0082d514a5dd3e5abaa4e30e4988d3be29e287be1aae33a7d18dc5c71a
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.22
1
+ 0.1.23
data/include/xot/pimpl.h CHANGED
@@ -25,11 +25,16 @@ namespace Xot
25
25
 
26
26
  PImpl (T* p) : Super(p) {}
27
27
 
28
- PImpl (const This& obj) : Super(new T(*obj)) {}
28
+ PImpl (const This& obj)
29
+ : Super(obj ? new T(*obj) : NULL)
30
+ {
31
+ }
29
32
 
30
33
  This& operator = (const This& obj)
31
34
  {
32
- if (&obj != this) reset(new T(*obj));
35
+ if (&obj == this) return *this;
36
+
37
+ this->reset(obj ? new T(*obj) : NULL);
33
38
  return *this;
34
39
  }
35
40
 
@@ -42,7 +47,7 @@ namespace Xot
42
47
 
43
48
  typedef std::shared_ptr<T> Super;
44
49
 
45
- typedef PImpl<T> This;
50
+ typedef PSharedImpl<T> This;
46
51
 
47
52
  public:
48
53
 
@@ -2,6 +2,7 @@
2
2
 
3
3
 
4
4
  require 'rake/task'
5
+ require 'rake/dsl_definition'
5
6
 
6
7
 
7
8
  module Xot
data/lib/xot/rake/util.rb CHANGED
@@ -227,8 +227,9 @@ module Xot
227
227
  ]
228
228
  s = flags.dup
229
229
  s << warning_opts.map {|s| " -W#{s}"}.join
230
- s << ' -std=c++11' if gcc?
231
- s << ' -std=c++11 -stdlib=libc++ -mmacosx-version-min=10.7' if clang?
230
+ s << " -arch arm64" if RUBY_PLATFORM =~ /arm64-darwin/
231
+ s << ' -std=c++17' if gcc?
232
+ s << ' -std=c++17 -stdlib=libc++ -mmacosx-version-min=10.7' if clang?
232
233
  s << ' ' + RbConfig::CONFIG['debugflags'] if debug?
233
234
  s.gsub!(/-O\d?\w*/, '-O0') if debug?
234
235
  s
@@ -295,8 +296,9 @@ module Xot
295
296
  end
296
297
 
297
298
  def cxxflags()
298
- flags = env :CXXFLAGS, RbConfig::CONFIG['CXXFLAGS']
299
- make_cflags flags
299
+ cflags = env :CFLAGS, RbConfig::CONFIG['CFLAGS']
300
+ cxxflags = env :CXXFLAGS, RbConfig::CONFIG['CXXFLAGS']
301
+ make_cflags "#{cflags} #{cxxflags}"
300
302
  end
301
303
 
302
304
  def arflags()
data/lib/xot/rake.rb CHANGED
@@ -2,6 +2,7 @@
2
2
 
3
3
 
4
4
  require 'rbconfig'
5
+ require 'rake'
5
6
  require 'rake/loaders/makefile'
6
7
  require 'rake/testtask'
7
8
  require 'xot/rake/alias_task'
data/xot.gemspec CHANGED
@@ -26,7 +26,7 @@ Gem::Specification.new do |s|
26
26
  s.homepage = "https://github.com/xord/xot"
27
27
 
28
28
  s.platform = Gem::Platform::RUBY
29
- s.required_ruby_version = '~> 2'
29
+ s.required_ruby_version = '>= 2.6.0'
30
30
 
31
31
  s.add_development_dependency 'test-unit'
32
32
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: xot
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.22
4
+ version: 0.1.23
5
5
  platform: ruby
6
6
  authors:
7
7
  - xordog
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-02-13 00:00:00.000000000 Z
11
+ date: 2021-10-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: test-unit
@@ -92,16 +92,16 @@ require_paths:
92
92
  - lib
93
93
  required_ruby_version: !ruby/object:Gem::Requirement
94
94
  requirements:
95
- - - "~>"
95
+ - - ">="
96
96
  - !ruby/object:Gem::Version
97
- version: '2'
97
+ version: 2.6.0
98
98
  required_rubygems_version: !ruby/object:Gem::Requirement
99
99
  requirements:
100
100
  - - ">="
101
101
  - !ruby/object:Gem::Version
102
102
  version: '0'
103
103
  requirements: []
104
- rubygems_version: 3.0.3
104
+ rubygems_version: 3.2.22
105
105
  signing_key:
106
106
  specification_version: 4
107
107
  summary: A Utility library for C++ developemt.