bkietz commented on code in PR #6426:
URL: https://github.com/apache/arrow-rs/pull/6426#discussion_r1768829858
##########
arrow-ipc/regen.sh:
##########
@@ -99,37 +102,38 @@ for f in `ls *.rs`; do
fi
echo "Modifying: $f"
- sed -i '' '/extern crate flatbuffers;/d' $f
- sed -i '' '/use self::flatbuffers::EndianScalar;/d' $f
- sed -i '' '/\#\[allow(unused_imports, dead_code)\]/d' $f
- sed -i '' '/pub mod org {/d' $f
- sed -i '' '/pub mod apache {/d' $f
- sed -i '' '/pub mod arrow {/d' $f
- sed -i '' '/pub mod flatbuf {/d' $f
- sed -i '' '/} \/\/ pub mod flatbuf/d' $f
- sed -i '' '/} \/\/ pub mod arrow/d' $f
- sed -i '' '/} \/\/ pub mod apache/d' $f
- sed -i '' '/} \/\/ pub mod org/d' $f
- sed -i '' '/use core::mem;/d' $f
- sed -i '' '/use core::cmp::Ordering;/d' $f
- sed -i '' '/use self::flatbuffers::{EndianScalar, Follow};/d' $f
+ sed --in-place='' '/extern crate flatbuffers;/d' $f
+ sed --in-place='' '/use self::flatbuffers::EndianScalar;/d' $f
+ sed --in-place='' '/\#\[allow(unused_imports, dead_code)\]/d' $f
+ sed --in-place='' '/pub mod org {/d' $f
+ sed --in-place='' '/pub mod apache {/d' $f
+ sed --in-place='' '/pub mod arrow {/d' $f
+ sed --in-place='' '/pub mod flatbuf {/d' $f
+ sed --in-place='' '/} \/\/ pub mod flatbuf/d' $f
+ sed --in-place='' '/} \/\/ pub mod arrow/d' $f
+ sed --in-place='' '/} \/\/ pub mod apache/d' $f
+ sed --in-place='' '/} \/\/ pub mod org/d' $f
+ sed --in-place='' '/use core::mem;/d' $f
+ sed --in-place='' '/use core::cmp::Ordering;/d' $f
+ sed --in-place='' '/use self::flatbuffers::{EndianScalar, Follow};/d' $f
# required by flatc 1.12.0+
- sed -i '' "/\#\!\[allow(unused_imports, dead_code)\]/d" $f
+ sed --in-place='' "/\#\!\[allow(unused_imports, dead_code)\]/d" $f
for name in ${names[@]}; do
- sed -i '' "/use crate::${name}::\*;/d" $f
- sed -i '' "s/use self::flatbuffers::Verifiable;/use
flatbuffers::Verifiable;/g" $f
+ sed --in-place='' "/use crate::${name}::\*;/d" $f
+ sed --in-place='' "s/use self::flatbuffers::Verifiable;/use
flatbuffers::Verifiable;/g" $f
done
# Replace all occurrences of "type__" with "type_", "TYPE__" with "TYPE_".
- sed -i '' 's/type__/type_/g' $f
- sed -i '' 's/TYPE__/TYPE_/g' $f
+ sed --in-place='' 's/type__/type_/g' $f
+ sed --in-place='' 's/TYPE__/TYPE_/g' $f
# Some files need prefixes
if [[ $f == "File.rs" ]]; then
# Now prefix the file with the static contents
echo -e "${PREFIX}" "${SCHEMA_IMPORT}" | cat - $f > temp && mv temp $f
elif [[ $f == "Message.rs" ]]; then
+ sed --in-place='' 's/List<Int16>/\`List<Int16>\`/g' $f
Review Comment:
I think this was another manual edit of the generated files. Moving it here
should simplify the next time `regen.sh` is used. Are there any other manual
edits which I haven't noticed?
##########
arrow-ipc/Cargo.toml:
##########
@@ -39,7 +39,7 @@ arrow-buffer = { workspace = true }
arrow-cast = { workspace = true }
arrow-data = { workspace = true }
arrow-schema = { workspace = true }
-flatbuffers = { version = "24.3.25", default-features = false }
+flatbuffers = { default-features = false, git =
"https://github.com/bkietz/flatbuffers.git", branch =
"push-alignment-for-structs" }
Review Comment:
Until https://github.com/google/flatbuffers/pull/8398 merges
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]