File tree Expand file tree Collapse file tree 2 files changed +28
-1
lines changed Expand file tree Collapse file tree 2 files changed +28
-1
lines changed Original file line number Diff line number Diff line change @@ -44,16 +44,41 @@ jobs:
4444 run : |
4545 cargo update -p serde_test --precise 1.0.163
4646 cargo update -p serde --precise 1.0.69
47- - name : Tests
47+ - name : Build
4848 run : |
49+ cargo build -v --no-default-features
4950 cargo build --verbose --features "${{ matrix.features }}"
51+ - name : Tests
52+ run : |
5053 cargo doc --verbose --features "${{ matrix.features }}" --no-deps
5154 cargo test --verbose --features "${{ matrix.features }}"
5255 cargo test --release --verbose --features "${{ matrix.features }}"
5356 - name : Test run benchmarks
5457 if : matrix.bench != ''
5558 run : cargo test -v --benches
5659
60+ nostd :
61+ runs-on : ubuntu-latest
62+ continue-on-error : false
63+ strategy :
64+ matrix :
65+ include :
66+ - rust : stable
67+ target : thumbv6m-none-eabi
68+ features : zeroize
69+
70+ name : nostd/${{ matrix.target }}/${{ matrix.rust }}
71+ steps :
72+ - uses : actions/checkout@v4
73+ - uses : dtolnay/rust-toolchain@stable
74+ with :
75+ toolchain : ${{ matrix.rust }}
76+ targets : ${{ matrix.target }}
77+ - name : Tests
78+ run : |
79+ cargo rustc "--target=${{ matrix.target }}" --no-default-features --features "${{ matrix.features }}"
80+
81+
5782 miri :
5883 runs-on : ubuntu-latest
5984 steps :
Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ use std::fmt;
55use std:: hash:: { Hash , Hasher } ;
66use std:: mem:: MaybeUninit ;
77use std:: ops:: { Deref , DerefMut } ;
8+ #[ cfg( feature="std" ) ]
89use std:: path:: Path ;
910use std:: ptr;
1011use std:: slice;
@@ -502,6 +503,7 @@ impl<const CAP: usize> fmt::Debug for ArrayString<CAP>
502503 fn fmt ( & self , f : & mut fmt:: Formatter ) -> fmt:: Result { ( * * self ) . fmt ( f) }
503504}
504505
506+ #[ cfg( feature="std" ) ]
505507impl < const CAP : usize > AsRef < Path > for ArrayString < CAP > {
506508 fn as_ref ( & self ) -> & Path {
507509 self . as_str ( ) . as_ref ( )
You can’t perform that action at this time.
0 commit comments