Author Topic: py file is treated as c/objective-c ?!?  (Read 333 times)

kmk

  • Community Member
  • Posts: 15
  • Hero Points: 0
py file is treated as c/objective-c ?!?
« on: January 29, 2019, 05:22:43 pm »
I'm baffled -- ONE python file is being treated as c, based on comment blocks.  Other py files are fine.  In fact, this file was fine until today.  I've been working on this file on and off for weeks.  When i bring up help/about, i noticed that the problematic file has:  Language: .py (Objective-C) whilst the 'normal' files have Language: .py (Python)

I checked the extensions associated with Objective-C and py is not in the list.  Similarly, python is associated with py.

I'm using  23.0.0.11 64bit on sles12sp1 kernel 3.12.51-60.20-default

Since i have a win/lin license, i opened the file in win (same se build info), and it worked fine!

How did i associate this one file with another language, such that it persists across opens/closes of the file, as well as runs of vs?
How might i correct this?

Many thanks in advance for any help with this!

hs2

  • Senior Community Member
  • Posts: 2738
  • Hero Points: 288
Re: py file is treated as c/objective-c ?!?
« Reply #1 on: January 29, 2019, 06:20:08 pm »
This might be caused by manual (accidental) 'Document>Select Mode' override. It's a feature :)
HS2

kmk

  • Community Member
  • Posts: 15
  • Hero Points: 0
Re: py file is treated as c/objective-c ?!?
« Reply #2 on: January 29, 2019, 06:56:17 pm »
You're absolutely correct, many thanks!!  wow, just wow...

No idea how i did that, but i obviously did somehow.  One of the (many) features of vs that i haven't used (intentionally).

Thanks again!