Skip to content

Commit

Permalink
Fix deprecated function use, ignored return (#139)
Browse files Browse the repository at this point in the history
* Fix deprecated

* fix strings.Title deprecation
  • Loading branch information
angaz authored Nov 8, 2022
1 parent 003d279 commit 8e2c93d
Show file tree
Hide file tree
Showing 17 changed files with 169 additions and 163 deletions.
30 changes: 15 additions & 15 deletions generator/.snapshots/Test118CustomPrefixExampleFile-og
Original file line number Diff line number Diff line change
Expand Up @@ -2862,12 +2862,12 @@
(string) (len=43) "\tCustom_prefix_TestHyphen Sanitizing = iota",
(string) (len=67) "\t// Custom_prefix_HyphenStart is a Sanitizing of type -HyphenStart.",
(string) (len=26) "\tCustom_prefix_HyphenStart",
(string) (len=76) "\t// Custom_prefix__underscoreFirst is a Sanitizing of type _underscoreFirst.",
(string) (len=31) "\tCustom_prefix__underscoreFirst",
(string) (len=68) "\t// Custom_prefix_0numberFirst is a Sanitizing of type 0numberFirst.",
(string) (len=27) "\tCustom_prefix_0numberFirst",
(string) (len=64) "\t// Custom_prefix_123456789a is a Sanitizing of type 123456789a.",
(string) (len=25) "\tCustom_prefix_123456789a",
(string) (len=76) "\t// Custom_prefix__UnderscoreFirst is a Sanitizing of type _UnderscoreFirst.",
(string) (len=31) "\tCustom_prefix__UnderscoreFirst",
(string) (len=68) "\t// Custom_prefix_0NumberFirst is a Sanitizing of type 0NumberFirst.",
(string) (len=27) "\tCustom_prefix_0NumberFirst",
(string) (len=64) "\t// Custom_prefix_123456789A is a Sanitizing of type 123456789A.",
(string) (len=25) "\tCustom_prefix_123456789A",
(string) (len=65) "\t// Custom_prefix_123123Asdf is a Sanitizing of type 123123-Asdf.",
(string) (len=25) "\tCustom_prefix_123123Asdf",
(string) (len=70) "\t// Custom_prefix_EndingHyphen is a Sanitizing of type Ending-Hyphen-.",
Expand All @@ -2881,9 +2881,9 @@
(string) (len=43) "var _SanitizingMap = map[Sanitizing]string{",
(string) (len=55) "\tCustom_prefix_TestHyphen: _SanitizingName[0:11],",
(string) (len=56) "\tCustom_prefix_HyphenStart: _SanitizingName[11:23],",
(string) (len=56) "\tCustom_prefix__underscoreFirst: _SanitizingName[23:39],",
(string) (len=56) "\tCustom_prefix_0numberFirst: _SanitizingName[39:51],",
(string) (len=56) "\tCustom_prefix_123456789a: _SanitizingName[51:61],",
(string) (len=56) "\tCustom_prefix__UnderscoreFirst: _SanitizingName[23:39],",
(string) (len=56) "\tCustom_prefix_0NumberFirst: _SanitizingName[39:51],",
(string) (len=56) "\tCustom_prefix_123456789A: _SanitizingName[51:61],",
(string) (len=56) "\tCustom_prefix_123123Asdf: _SanitizingName[61:72],",
(string) (len=56) "\tCustom_prefix_EndingHyphen: _SanitizingName[72:86],",
(string) (len=1) "}",
Expand All @@ -2901,12 +2901,12 @@
(string) (len=67) "\tstrings.ToLower(_SanitizingName[0:11]): Custom_prefix_TestHyphen,",
(string) (len=68) "\t_SanitizingName[11:23]: Custom_prefix_HyphenStart,",
(string) (len=68) "\tstrings.ToLower(_SanitizingName[11:23]): Custom_prefix_HyphenStart,",
(string) (len=73) "\t_SanitizingName[23:39]: Custom_prefix__underscoreFirst,",
(string) (len=73) "\tstrings.ToLower(_SanitizingName[23:39]): Custom_prefix__underscoreFirst,",
(string) (len=69) "\t_SanitizingName[39:51]: Custom_prefix_0numberFirst,",
(string) (len=69) "\tstrings.ToLower(_SanitizingName[39:51]): Custom_prefix_0numberFirst,",
(string) (len=67) "\t_SanitizingName[51:61]: Custom_prefix_123456789a,",
(string) (len=67) "\tstrings.ToLower(_SanitizingName[51:61]): Custom_prefix_123456789a,",
(string) (len=73) "\t_SanitizingName[23:39]: Custom_prefix__UnderscoreFirst,",
(string) (len=73) "\tstrings.ToLower(_SanitizingName[23:39]): Custom_prefix__UnderscoreFirst,",
(string) (len=69) "\t_SanitizingName[39:51]: Custom_prefix_0NumberFirst,",
(string) (len=69) "\tstrings.ToLower(_SanitizingName[39:51]): Custom_prefix_0NumberFirst,",
(string) (len=67) "\t_SanitizingName[51:61]: Custom_prefix_123456789A,",
(string) (len=67) "\tstrings.ToLower(_SanitizingName[51:61]): Custom_prefix_123456789A,",
(string) (len=67) "\t_SanitizingName[61:72]: Custom_prefix_123123Asdf,",
(string) (len=67) "\tstrings.ToLower(_SanitizingName[61:72]): Custom_prefix_123123Asdf,",
(string) (len=69) "\t_SanitizingName[72:86]: Custom_prefix_EndingHyphen,",
Expand Down
30 changes: 15 additions & 15 deletions generator/.snapshots/Test118ExampleFile-og
Original file line number Diff line number Diff line change
Expand Up @@ -1757,12 +1757,12 @@
(string) (len=39) "\tSanitizingTestHyphen Sanitizing = iota",
(string) (len=63) "\t// SanitizingHyphenStart is a Sanitizing of type -HyphenStart.",
(string) (len=22) "\tSanitizingHyphenStart",
(string) (len=72) "\t// Sanitizing_underscoreFirst is a Sanitizing of type _underscoreFirst.",
(string) (len=27) "\tSanitizing_underscoreFirst",
(string) (len=64) "\t// Sanitizing0numberFirst is a Sanitizing of type 0numberFirst.",
(string) (len=23) "\tSanitizing0numberFirst",
(string) (len=60) "\t// Sanitizing123456789a is a Sanitizing of type 123456789a.",
(string) (len=21) "\tSanitizing123456789a",
(string) (len=72) "\t// Sanitizing_UnderscoreFirst is a Sanitizing of type _UnderscoreFirst.",
(string) (len=27) "\tSanitizing_UnderscoreFirst",
(string) (len=64) "\t// Sanitizing0NumberFirst is a Sanitizing of type 0NumberFirst.",
(string) (len=23) "\tSanitizing0NumberFirst",
(string) (len=60) "\t// Sanitizing123456789A is a Sanitizing of type 123456789A.",
(string) (len=21) "\tSanitizing123456789A",
(string) (len=61) "\t// Sanitizing123123Asdf is a Sanitizing of type 123123-Asdf.",
(string) (len=21) "\tSanitizing123123Asdf",
(string) (len=66) "\t// SanitizingEndingHyphen is a Sanitizing of type Ending-Hyphen-.",
Expand Down Expand Up @@ -1793,9 +1793,9 @@
(string) (len=43) "var _SanitizingMap = map[Sanitizing]string{",
(string) (len=51) "\tSanitizingTestHyphen: _SanitizingName[0:11],",
(string) (len=52) "\tSanitizingHyphenStart: _SanitizingName[11:23],",
(string) (len=52) "\tSanitizing_underscoreFirst: _SanitizingName[23:39],",
(string) (len=52) "\tSanitizing0numberFirst: _SanitizingName[39:51],",
(string) (len=52) "\tSanitizing123456789a: _SanitizingName[51:61],",
(string) (len=52) "\tSanitizing_UnderscoreFirst: _SanitizingName[23:39],",
(string) (len=52) "\tSanitizing0NumberFirst: _SanitizingName[39:51],",
(string) (len=52) "\tSanitizing123456789A: _SanitizingName[51:61],",
(string) (len=52) "\tSanitizing123123Asdf: _SanitizingName[61:72],",
(string) (len=52) "\tSanitizingEndingHyphen: _SanitizingName[72:86],",
(string) (len=1) "}",
Expand All @@ -1813,12 +1813,12 @@
(string) (len=63) "\tstrings.ToLower(_SanitizingName[0:11]): SanitizingTestHyphen,",
(string) (len=64) "\t_SanitizingName[11:23]: SanitizingHyphenStart,",
(string) (len=64) "\tstrings.ToLower(_SanitizingName[11:23]): SanitizingHyphenStart,",
(string) (len=69) "\t_SanitizingName[23:39]: Sanitizing_underscoreFirst,",
(string) (len=69) "\tstrings.ToLower(_SanitizingName[23:39]): Sanitizing_underscoreFirst,",
(string) (len=65) "\t_SanitizingName[39:51]: Sanitizing0numberFirst,",
(string) (len=65) "\tstrings.ToLower(_SanitizingName[39:51]): Sanitizing0numberFirst,",
(string) (len=63) "\t_SanitizingName[51:61]: Sanitizing123456789a,",
(string) (len=63) "\tstrings.ToLower(_SanitizingName[51:61]): Sanitizing123456789a,",
(string) (len=69) "\t_SanitizingName[23:39]: Sanitizing_UnderscoreFirst,",
(string) (len=69) "\tstrings.ToLower(_SanitizingName[23:39]): Sanitizing_UnderscoreFirst,",
(string) (len=65) "\t_SanitizingName[39:51]: Sanitizing0NumberFirst,",
(string) (len=65) "\tstrings.ToLower(_SanitizingName[39:51]): Sanitizing0NumberFirst,",
(string) (len=63) "\t_SanitizingName[51:61]: Sanitizing123456789A,",
(string) (len=63) "\tstrings.ToLower(_SanitizingName[51:61]): Sanitizing123456789A,",
(string) (len=63) "\t_SanitizingName[61:72]: Sanitizing123123Asdf,",
(string) (len=63) "\tstrings.ToLower(_SanitizingName[61:72]): Sanitizing123123Asdf,",
(string) (len=65) "\t_SanitizingName[72:86]: SanitizingEndingHyphen,",
Expand Down
30 changes: 15 additions & 15 deletions generator/.snapshots/Test118ExampleFileMoreOptions-og
Original file line number Diff line number Diff line change
Expand Up @@ -1897,12 +1897,12 @@
(string) (len=39) "\tSanitizingTestHyphen Sanitizing = iota",
(string) (len=63) "\t// SanitizingHyphenStart is a Sanitizing of type -HyphenStart.",
(string) (len=22) "\tSanitizingHyphenStart",
(string) (len=72) "\t// Sanitizing_underscoreFirst is a Sanitizing of type _underscoreFirst.",
(string) (len=27) "\tSanitizing_underscoreFirst",
(string) (len=64) "\t// Sanitizing0numberFirst is a Sanitizing of type 0numberFirst.",
(string) (len=23) "\tSanitizing0numberFirst",
(string) (len=60) "\t// Sanitizing123456789a is a Sanitizing of type 123456789a.",
(string) (len=21) "\tSanitizing123456789a",
(string) (len=72) "\t// Sanitizing_UnderscoreFirst is a Sanitizing of type _UnderscoreFirst.",
(string) (len=27) "\tSanitizing_UnderscoreFirst",
(string) (len=64) "\t// Sanitizing0NumberFirst is a Sanitizing of type 0NumberFirst.",
(string) (len=23) "\tSanitizing0NumberFirst",
(string) (len=60) "\t// Sanitizing123456789A is a Sanitizing of type 123456789A.",
(string) (len=21) "\tSanitizing123456789A",
(string) (len=61) "\t// Sanitizing123123Asdf is a Sanitizing of type 123123-Asdf.",
(string) (len=21) "\tSanitizing123123Asdf",
(string) (len=66) "\t// SanitizingEndingHyphen is a Sanitizing of type Ending-Hyphen-.",
Expand Down Expand Up @@ -1933,9 +1933,9 @@
(string) (len=43) "var _SanitizingMap = map[Sanitizing]string{",
(string) (len=51) "\tSanitizingTestHyphen: _SanitizingName[0:11],",
(string) (len=52) "\tSanitizingHyphenStart: _SanitizingName[11:23],",
(string) (len=52) "\tSanitizing_underscoreFirst: _SanitizingName[23:39],",
(string) (len=52) "\tSanitizing0numberFirst: _SanitizingName[39:51],",
(string) (len=52) "\tSanitizing123456789a: _SanitizingName[51:61],",
(string) (len=52) "\tSanitizing_UnderscoreFirst: _SanitizingName[23:39],",
(string) (len=52) "\tSanitizing0NumberFirst: _SanitizingName[39:51],",
(string) (len=52) "\tSanitizing123456789A: _SanitizingName[51:61],",
(string) (len=52) "\tSanitizing123123Asdf: _SanitizingName[61:72],",
(string) (len=52) "\tSanitizingEndingHyphen: _SanitizingName[72:86],",
(string) (len=1) "}",
Expand All @@ -1953,12 +1953,12 @@
(string) (len=63) "\tstrings.ToLower(_SanitizingName[0:11]): SanitizingTestHyphen,",
(string) (len=64) "\t_SanitizingName[11:23]: SanitizingHyphenStart,",
(string) (len=64) "\tstrings.ToLower(_SanitizingName[11:23]): SanitizingHyphenStart,",
(string) (len=69) "\t_SanitizingName[23:39]: Sanitizing_underscoreFirst,",
(string) (len=69) "\tstrings.ToLower(_SanitizingName[23:39]): Sanitizing_underscoreFirst,",
(string) (len=65) "\t_SanitizingName[39:51]: Sanitizing0numberFirst,",
(string) (len=65) "\tstrings.ToLower(_SanitizingName[39:51]): Sanitizing0numberFirst,",
(string) (len=63) "\t_SanitizingName[51:61]: Sanitizing123456789a,",
(string) (len=63) "\tstrings.ToLower(_SanitizingName[51:61]): Sanitizing123456789a,",
(string) (len=69) "\t_SanitizingName[23:39]: Sanitizing_UnderscoreFirst,",
(string) (len=69) "\tstrings.ToLower(_SanitizingName[23:39]): Sanitizing_UnderscoreFirst,",
(string) (len=65) "\t_SanitizingName[39:51]: Sanitizing0NumberFirst,",
(string) (len=65) "\tstrings.ToLower(_SanitizingName[39:51]): Sanitizing0NumberFirst,",
(string) (len=63) "\t_SanitizingName[51:61]: Sanitizing123456789A,",
(string) (len=63) "\tstrings.ToLower(_SanitizingName[51:61]): Sanitizing123456789A,",
(string) (len=63) "\t_SanitizingName[61:72]: Sanitizing123123Asdf,",
(string) (len=63) "\tstrings.ToLower(_SanitizingName[61:72]): Sanitizing123123Asdf,",
(string) (len=65) "\t_SanitizingName[72:86]: SanitizingEndingHyphen,",
Expand Down
30 changes: 15 additions & 15 deletions generator/.snapshots/Test118NoPrefixExampleFile-og
Original file line number Diff line number Diff line change
Expand Up @@ -989,12 +989,12 @@
(string) (len=29) "\tTestHyphen Sanitizing = iota",
(string) (len=54) "\t// XHyphenStart is a Sanitizing of type -HyphenStart.",
(string) (len=13) "\tXHyphenStart",
(string) (len=63) "\t// X_underscoreFirst is a Sanitizing of type _underscoreFirst.",
(string) (len=18) "\tX_underscoreFirst",
(string) (len=55) "\t// X0numberFirst is a Sanitizing of type 0numberFirst.",
(string) (len=14) "\tX0numberFirst",
(string) (len=51) "\t// X123456789a is a Sanitizing of type 123456789a.",
(string) (len=12) "\tX123456789a",
(string) (len=63) "\t// X_UnderscoreFirst is a Sanitizing of type _UnderscoreFirst.",
(string) (len=18) "\tX_UnderscoreFirst",
(string) (len=55) "\t// X0NumberFirst is a Sanitizing of type 0NumberFirst.",
(string) (len=14) "\tX0NumberFirst",
(string) (len=51) "\t// X123456789A is a Sanitizing of type 123456789A.",
(string) (len=12) "\tX123456789A",
(string) (len=52) "\t// X123123Asdf is a Sanitizing of type 123123-Asdf.",
(string) (len=12) "\tX123123Asdf",
(string) (len=56) "\t// EndingHyphen is a Sanitizing of type Ending-Hyphen-.",
Expand All @@ -1008,9 +1008,9 @@
(string) (len=43) "var _SanitizingMap = map[Sanitizing]string{",
(string) (len=42) "\tTestHyphen: _SanitizingName[0:11],",
(string) (len=43) "\tXHyphenStart: _SanitizingName[11:23],",
(string) (len=43) "\tX_underscoreFirst: _SanitizingName[23:39],",
(string) (len=43) "\tX0numberFirst: _SanitizingName[39:51],",
(string) (len=43) "\tX123456789a: _SanitizingName[51:61],",
(string) (len=43) "\tX_UnderscoreFirst: _SanitizingName[23:39],",
(string) (len=43) "\tX0NumberFirst: _SanitizingName[39:51],",
(string) (len=43) "\tX123456789A: _SanitizingName[51:61],",
(string) (len=43) "\tX123123Asdf: _SanitizingName[61:72],",
(string) (len=43) "\tEndingHyphen: _SanitizingName[72:86],",
(string) (len=1) "}",
Expand All @@ -1028,12 +1028,12 @@
(string) (len=53) "\tstrings.ToLower(_SanitizingName[0:11]): TestHyphen,",
(string) (len=55) "\t_SanitizingName[11:23]: XHyphenStart,",
(string) (len=55) "\tstrings.ToLower(_SanitizingName[11:23]): XHyphenStart,",
(string) (len=60) "\t_SanitizingName[23:39]: X_underscoreFirst,",
(string) (len=60) "\tstrings.ToLower(_SanitizingName[23:39]): X_underscoreFirst,",
(string) (len=56) "\t_SanitizingName[39:51]: X0numberFirst,",
(string) (len=56) "\tstrings.ToLower(_SanitizingName[39:51]): X0numberFirst,",
(string) (len=54) "\t_SanitizingName[51:61]: X123456789a,",
(string) (len=54) "\tstrings.ToLower(_SanitizingName[51:61]): X123456789a,",
(string) (len=60) "\t_SanitizingName[23:39]: X_UnderscoreFirst,",
(string) (len=60) "\tstrings.ToLower(_SanitizingName[23:39]): X_UnderscoreFirst,",
(string) (len=56) "\t_SanitizingName[39:51]: X0NumberFirst,",
(string) (len=56) "\tstrings.ToLower(_SanitizingName[39:51]): X0NumberFirst,",
(string) (len=54) "\t_SanitizingName[51:61]: X123456789A,",
(string) (len=54) "\tstrings.ToLower(_SanitizingName[51:61]): X123456789A,",
(string) (len=54) "\t_SanitizingName[61:72]: X123123Asdf,",
(string) (len=54) "\tstrings.ToLower(_SanitizingName[61:72]): X123123Asdf,",
(string) (len=55) "\t_SanitizingName[72:86]: EndingHyphen,",
Expand Down
22 changes: 11 additions & 11 deletions generator/.snapshots/Test118NoPrefixExampleFileWithSnakeToCamel-og
Original file line number Diff line number Diff line change
Expand Up @@ -989,12 +989,12 @@
(string) (len=29) "\tTestHyphen Sanitizing = iota",
(string) (len=54) "\t// XHyphenStart is a Sanitizing of type -HyphenStart.",
(string) (len=13) "\tXHyphenStart",
(string) (len=62) "\t// XUnderscoreFirst is a Sanitizing of type _underscoreFirst.",
(string) (len=62) "\t// XUnderscoreFirst is a Sanitizing of type _UnderscoreFirst.",
(string) (len=17) "\tXUnderscoreFirst",
(string) (len=55) "\t// X0numberFirst is a Sanitizing of type 0numberFirst.",
(string) (len=14) "\tX0numberFirst",
(string) (len=51) "\t// X123456789a is a Sanitizing of type 123456789a.",
(string) (len=12) "\tX123456789a",
(string) (len=55) "\t// X0NumberFirst is a Sanitizing of type 0NumberFirst.",
(string) (len=14) "\tX0NumberFirst",
(string) (len=51) "\t// X123456789A is a Sanitizing of type 123456789A.",
(string) (len=12) "\tX123456789A",
(string) (len=52) "\t// X123123Asdf is a Sanitizing of type 123123-Asdf.",
(string) (len=12) "\tX123123Asdf",
(string) (len=56) "\t// EndingHyphen is a Sanitizing of type Ending-Hyphen-.",
Expand All @@ -1009,8 +1009,8 @@
(string) (len=41) "\tTestHyphen: _SanitizingName[0:11],",
(string) (len=42) "\tXHyphenStart: _SanitizingName[11:23],",
(string) (len=42) "\tXUnderscoreFirst: _SanitizingName[23:39],",
(string) (len=42) "\tX0numberFirst: _SanitizingName[39:51],",
(string) (len=42) "\tX123456789a: _SanitizingName[51:61],",
(string) (len=42) "\tX0NumberFirst: _SanitizingName[39:51],",
(string) (len=42) "\tX123456789A: _SanitizingName[51:61],",
(string) (len=42) "\tX123123Asdf: _SanitizingName[61:72],",
(string) (len=42) "\tEndingHyphen: _SanitizingName[72:86],",
(string) (len=1) "}",
Expand All @@ -1030,10 +1030,10 @@
(string) (len=55) "\tstrings.ToLower(_SanitizingName[11:23]): XHyphenStart,",
(string) (len=59) "\t_SanitizingName[23:39]: XUnderscoreFirst,",
(string) (len=59) "\tstrings.ToLower(_SanitizingName[23:39]): XUnderscoreFirst,",
(string) (len=56) "\t_SanitizingName[39:51]: X0numberFirst,",
(string) (len=56) "\tstrings.ToLower(_SanitizingName[39:51]): X0numberFirst,",
(string) (len=54) "\t_SanitizingName[51:61]: X123456789a,",
(string) (len=54) "\tstrings.ToLower(_SanitizingName[51:61]): X123456789a,",
(string) (len=56) "\t_SanitizingName[39:51]: X0NumberFirst,",
(string) (len=56) "\tstrings.ToLower(_SanitizingName[39:51]): X0NumberFirst,",
(string) (len=54) "\t_SanitizingName[51:61]: X123456789A,",
(string) (len=54) "\tstrings.ToLower(_SanitizingName[51:61]): X123456789A,",
(string) (len=54) "\t_SanitizingName[61:72]: X123123Asdf,",
(string) (len=54) "\tstrings.ToLower(_SanitizingName[61:72]): X123123Asdf,",
(string) (len=55) "\t_SanitizingName[72:86]: EndingHyphen,",
Expand Down
Loading

0 comments on commit 8e2c93d

Please sign in to comment.