Skip to content

Commit

Permalink
Fix README.md in swiftc-and-cargo (#132)
Browse files Browse the repository at this point in the history
  • Loading branch information
NiwakaDev authored Jan 8, 2023
1 parent 1f1ae99 commit b7b84d0
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions book/src/building/swiftc-and-cargo/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,10 @@ run()

```swift
// lib.swift
func print_hello_swift() {
print("Hello from Swift")
}

func run() {
print_hello_rust()
}
Expand Down Expand Up @@ -124,6 +128,7 @@ swiftc -L target/x86_64-apple-darwin/debug/ -lswift_and_rust -import-objc-header
```

```sh
chmod +x build-swiftc-links-rust.sh
./build-swiftc-links-rust.sh
./main
# The output should be "Hello from Rust"
Expand Down

0 comments on commit b7b84d0

Please sign in to comment.