I am trying to find out whether my file pointer is at the EOF like in this example code: (EDITED)

```
f = open("test.dat")

someFunctionDoingStuffOn_f(f)

if f == EOF:         # to keep something like this would be important in my case
    print "EOF reached"
else:
    print "Not EOF"

```

But I do not know if there is anything like this available in Python.

I have edited the question by adding someFunctionDoingStuffOn\_f(f), because it might be that I do not know what happened with f before hand. This excludes some approaches.