0
votes

I have seen similar questions and I've examined them but I didn't solve any problem. I have all the sources and the error is about two units I've written myself and they are both in the main directory of my app. I've been having the problem since I used the template method of writing classes. Here's the situation with my app: I wrote a new unit for implementing link list for any kind of object so I wrote TLinkList<T> = class which works perfectly fine. Since the time I wrote this class, I'm having this problem. It doesn't compile in normal situations and what I have to do is to comment some of the code in ApFileIO unit and compile the program, and then uncomment the code again! I'm tired of commenting and uncommenting my codes, so I was wondering if there is anyway to fix this error. Thx in advance.

1
Even the F2051 error reference didn't help ?TLama
No it didn't, because the sources are available and it's a very simple compile. I just don't get why this error happens for my project O_OJavid
Do you have any packages? Is ApCollections in one of your packages?David Heffernan
Yes it's used in one of my packages. Both my package and my main application use this unit. Delphi doesn't compile my package either showing the same error.Javid
Are there multiple copies of ApCollections.dcu on your machine?David Heffernan

1 Answers

0
votes

Believe it or not, the problem is solved by not using inline functions. I removed inline directives of unit *** (which is mentioned in the question subject) and ApCollections. This solved the problem. Thank you everybody for helping.