Skip to content

Commit

Permalink
oak_abi: Switch to Prost from protobuf-rust (project-oak#666)
Browse files Browse the repository at this point in the history
* Replacing protobuf-rust generated names with prost generated names was done with the following script

replace(){
 find oak sdk examples -type f -name '*.rs' -exec sed -i "s/$1/$2/g" {} \;
}

replace 'OakStatus::OAK_STATUS_UNSPECIFIED'  'OakStatus::Unspecified'
replace 'OakStatus::OK' 'OakStatus::Ok'
replace ERR_BAD_HANDLE ErrBadHandle
replace ERR_INVALID_ARGS ErrInvalidArgs
replace ERR_CHANNEL_CLOSED ErrChannelClosed
replace ERR_BUFFER_TOO_SMALL ErrBufferTooSmall
replace ERR_HANDLE_SPACE_TOO_SMALL ErrHandleSpaceTooSmall
replace ERR_OUT_OF_RANGE ErrOutOfRange
replace ERR_INTERNAL ErrInternal
replace ERR_TERMINATED ErrTerminated
replace ERR_CHANNEL_EMPTY ErrChannelEmpty

replace NOT_READY NotReady
replace READ_READY ReadReady
replace INVALID_CHANNEL InvalidChannel
replace ORPHANED Orphaned
  • Loading branch information
blaxill authored Mar 5, 2020
1 parent c4adba0 commit 3924ae3
Show file tree
Hide file tree
Showing 19 changed files with 191 additions and 458 deletions.
4 changes: 2 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 3924ae3

Please sign in to comment.