Skip to content
This repository was archived by the owner on Sep 30, 2018. It is now read-only.

Write Up 4 by Glenn LeBlanc - #4

Open
gl3nnleblanc wants to merge 2 commits into
donald-pinckney:masterfrom
gl3nnleblanc:master
Open

Write Up 4 by Glenn LeBlanc#4
gl3nnleblanc wants to merge 2 commits into
donald-pinckney:masterfrom
gl3nnleblanc:master

Conversation

@gl3nnleblanc

Copy link
Copy Markdown

No description provided.

@gl3nnleblanc

gl3nnleblanc commented Oct 12, 2016

Copy link
Copy Markdown
Author

This doesn't seem to work when I try to run it. I get the following error:
.build/debug/problem1
fatal error: ERROR!!! Could not read file: words: file /home/vagrant/Write-Up-4/problem1/Sources/readFile.swift, line 10
Current stack trace:
0 libswiftCore.so 0x00007f0b90a24300 swift_reportError + 117
1 libswiftCore.so 0x00007f0b90a35630 _swift_stdlib_reportFatalErrorInFile + 103
2 libswiftCore.so 0x00007f0b909db9f3 + 0
3 libswiftCore.so 0x00007f0b908451c3 + 0
4 libswiftCore.so 0x00007f0b909db960 + 0
5 libswiftCore.so 0x00007f0b908455ec + 0
6 libswiftCore.so 0x00007f0b90987ae9 + 0
7 libswiftCore.so 0x00007f0b908451c3 + 0
8 libswiftCore.so 0x00007f0b90844e40 _assertionFailed(StaticString, String, StaticString, UInt, flags : UInt32) -> Never + 144
9 problem1 0x0000000000402cd1 + 0
10 problem1 0x0000000000402dd9 + 0
11 libc.so.6 0x00007f0b8ea0f9d0 __libc_start_main + 240
12 problem1 0x00000000004026b9 + 0
Illegal instruction (core dumped)

I'm not too sure how to troubleshoot it, because the error message looks like it's a problem with readFile.swift. The file "words" is definitely present in the same directory as readFile. I modified main.swift and manually entered a word to guess, and that seemed to fix the error message (but breaks the purpose of the assignment).

@isoule

isoule commented Oct 12, 2016

Copy link
Copy Markdown

I am getting the same error. I looked at the readFile.swift and saw that there was a built in fatal error function at line 10. Needless to say... I don't understand it.

@gl3nnleblanc

gl3nnleblanc commented Oct 12, 2016

Copy link
Copy Markdown
Author

Fixed by moving the executable into the same directory as words (write-up-4/problem1/Sources), as said on Piazza.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants