Hi
Sorry i am a newbie, but i have a question: What is the reason that MAKE-INSTANCE is not exported from the LTK package?
Thank you matus
Hi Matus,
it should be exported from the common-lisp package. Which lisp are you using?
Peter
On Sun, Jun 26, 2011 at 10:44 PM, Matus Kmit simply.nitaai@gmail.com wrote:
Hi
Sorry i am a newbie, but i have a question: What is the reason that MAKE-INSTANCE is not exported from the LTK package?
Thank you matus
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
Thanks for the swift answer.
Let me correct myself: make-instance seems to be correctly exported by CL package (SBCL), but when i try to, let's say create an instance of a frame object in my user-defined package the interpreter signals a name colision between the FRAME symbols of LTK and my package, although i never defined any symbol with that name. i am simply using:
(make-instance 'frame :master nil ...)
i think the error refers to this "frame* class designator.. Do i have to qualify it somehow and if yes how does one do that?
That said, i have to admit, that i am still learning how to properly use lisp package system.
Thanks for any advice, Matus
On Sun, Jun 26, 2011 at 10:54 PM, Peter Herth herth@peter-herth.de wrote:
Hi Matus,
it should be exported from the common-lisp package. Which lisp are you using?
Peter
On Sun, Jun 26, 2011 at 10:44 PM, Matus Kmit simply.nitaai@gmail.com wrote:
Hi
Sorry i am a newbie, but i have a question: What is the reason that MAKE-INSTANCE is not exported from the LTK package?
Thank you matus
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
Hi Matus,
the common lisp package system is indeed a bit confusing at the beginning. Took me years to really master the details of it. In doubt, restart your lisp session to get a clean environment. The fail-safe environment is having your code in your own package and set up like this:
(in-package :cl-user) (defpackage :my-package-name (:use :common-lisp :ltk) (:export #:my-function))
(in-package :my-package-name)
(defun my-function () ...)
in this case you should be able to just use (make-instance 'frame ...) as frame is imported from the LTk package. If you are not using the LTk package you can alwas access its symbols with the package prefix, here ltk:frame. If you get any error, please paste the exact error message into the mail, this sometimes helps with debugging :)
Peter
On Mon, Jun 27, 2011 at 8:30 AM, Matus Kmit simply.nitaai@gmail.com wrote:
Thanks for the swift answer.
Let me correct myself: make-instance seems to be correctly exported by CL package (SBCL), but when i try to, let's say create an instance of a frame object in my user-defined package the interpreter signals a name colision between the FRAME symbols of LTK and my package, although i never defined any symbol with that name. i am simply using:
(make-instance 'frame :master nil ...)
i think the error refers to this "frame* class designator.. Do i have to qualify it somehow and if yes how does one do that?
That said, i have to admit, that i am still learning how to properly use lisp package system.
Thanks for any advice, Matus
On Sun, Jun 26, 2011 at 10:54 PM, Peter Herth herth@peter-herth.de wrote:
Hi Matus,
it should be exported from the common-lisp package. Which lisp are you using?
Peter
On Sun, Jun 26, 2011 at 10:44 PM, Matus Kmit simply.nitaai@gmail.com wrote:
Hi
Sorry i am a newbie, but i have a question: What is the reason that MAKE-INSTANCE is not exported from the LTK package?
Thank you matus
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
Hi Peter
Thanks for the advice. It is working now as you described.
Matus
On Mon, Jun 27, 2011 at 9:43 AM, Peter Herth herth@peter-herth.de wrote:
Hi Matus,
the common lisp package system is indeed a bit confusing at the beginning. Took me years to really master the details of it. In doubt, restart your lisp session to get a clean environment. The fail-safe environment is having your code in your own package and set up like this:
(in-package :cl-user) (defpackage :my-package-name (:use :common-lisp :ltk) (:export #:my-function))
(in-package :my-package-name)
(defun my-function () ...)
in this case you should be able to just use (make-instance 'frame ...) as frame is imported from the LTk package. If you are not using the LTk package you can alwas access its symbols with the package prefix, here ltk:frame. If you get any error, please paste the exact error message into the mail, this sometimes helps with debugging :)
Peter
On Mon, Jun 27, 2011 at 8:30 AM, Matus Kmit simply.nitaai@gmail.com wrote:
Thanks for the swift answer.
Let me correct myself: make-instance seems to be correctly exported by CL package (SBCL), but when i try to, let's say create an instance of a frame object in my user-defined package the interpreter signals a name colision between the FRAME symbols of LTK and my package, although i never defined any symbol with that name. i am simply using:
(make-instance 'frame :master nil ...)
i think the error refers to this "frame* class designator.. Do i have to qualify it somehow and if yes how does one do that?
That said, i have to admit, that i am still learning how to properly use lisp package system.
Thanks for any advice, Matus
On Sun, Jun 26, 2011 at 10:54 PM, Peter Herth herth@peter-herth.de wrote:
Hi Matus,
it should be exported from the common-lisp package. Which lisp are you using?
Peter
On Sun, Jun 26, 2011 at 10:44 PM, Matus Kmit simply.nitaai@gmail.com wrote:
Hi
Sorry i am a newbie, but i have a question: What is the reason that MAKE-INSTANCE is not exported from the LTK package?
Thank you matus
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
On 6/27/2011 2:30 AM, Matus Kmit wrote:
Thanks for the swift answer.
Let me correct myself: make-instance seems to be correctly exported by CL package (SBCL), but when i try to, let's say create an instance of a frame object in my user-defined package the interpreter signals a name colision between the FRAME symbols of LTK and my package, although i never defined any symbol with that name. i am simply using:
(make-instance 'frame :master nil ...)
i think the error refers to this "frame* class designator.. Do i have to qualify it somehow and if yes how does one do that?
That said, i have to admit, that i am still learning how to properly use lisp package system.
You have not divulged which Lisp you are using. With AllegroCL, if I open a project and happen to open a source file or two before compiling anything, the ACL IDE interns symbols as it finds them, and does so in my package because that is the only one it sees (well, aside from the packages it ships with, including common lisp. But it would not know about the LTk package until I compiled the whole project.)
Thus the solution is to start your Lisp, build your project (perhaps with ASDF), and then start poking around.
btw, the warning you are getting probably offers a restart to "unintern conflicting symbols" or some such and you can use that to remove the conflicts, but there is a gotcha: any source compiled thinking the symbol was in your package still needs to be recompiled. Uninterning just cleans up the packages, not your FASLs.
kt
Thanks for any advice, Matus
On Sun, Jun 26, 2011 at 10:54 PM, Peter Herthherth@peter-herth.de wrote:
Hi Matus,
it should be exported from the common-lisp package. Which lisp are you using?
Peter
On Sun, Jun 26, 2011 at 10:44 PM, Matus Kmitsimply.nitaai@gmail.com wrote:
Hi
Sorry i am a newbie, but i have a question: What is the reason that MAKE-INSTANCE is not exported from the LTK package?
Thank you matus
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
Sorry, i am using SBCL. My problem is solved now.
Thanks for the tip about uninterning symbols and recompilation. Matus
On Mon, Jun 27, 2011 at 12:02 PM, Ken Tilton kentilton@gmail.com wrote:
On 6/27/2011 2:30 AM, Matus Kmit wrote:
Thanks for the swift answer.
Let me correct myself: make-instance seems to be correctly exported by CL package (SBCL), but when i try to, let's say create an instance of a frame object in my user-defined package the interpreter signals a name colision between the FRAME symbols of LTK and my package, although i never defined any symbol with that name. i am simply using:
(make-instance 'frame :master nil ...)
i think the error refers to this "frame* class designator.. Do i have to qualify it somehow and if yes how does one do that?
That said, i have to admit, that i am still learning how to properly use lisp package system.
You have not divulged which Lisp you are using. With AllegroCL, if I open a project and happen to open a source file or two before compiling anything, the ACL IDE interns symbols as it finds them, and does so in my package because that is the only one it sees (well, aside from the packages it ships with, including common lisp. But it would not know about the LTk package until I compiled the whole project.)
Thus the solution is to start your Lisp, build your project (perhaps with ASDF), and then start poking around.
btw, the warning you are getting probably offers a restart to "unintern conflicting symbols" or some such and you can use that to remove the conflicts, but there is a gotcha: any source compiled thinking the symbol was in your package still needs to be recompiled. Uninterning just cleans up the packages, not your FASLs.
kt
Thanks for any advice, Matus
On Sun, Jun 26, 2011 at 10:54 PM, Peter Herthherth@peter-herth.de wrote:
Hi Matus,
it should be exported from the common-lisp package. Which lisp are you using?
Peter
On Sun, Jun 26, 2011 at 10:44 PM, Matus Kmitsimply.nitaai@gmail.com wrote:
Hi
Sorry i am a newbie, but i have a question: What is the reason that MAKE-INSTANCE is not exported from the LTK package?
Thank you matus
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user
ltk-user site list ltk-user@common-lisp.net http://common-lisp.net/mailman/listinfo/ltk-user