+(defun ada-xref-current-project-file (&optional no-user-question)
+ "Return the current project file name; never nil unless NO-USER-QUESTION.
+If NO-USER-QUESTION, don't prompt user for file. Call
+`ada-require-project-file' first if a project must exist."
+ (if (not (string= "" ada-prj-default-project-file))
+ ada-prj-default-project-file
+ (ada-prj-find-prj-file nil no-user-question)))
+
+(defun ada-xref-current-project (&optional no-user-question)
+ "Return the current project; nil if none.
+If NO-USER-QUESTION, don't prompt user for file. Call
+`ada-require-project-file' first if a project must exist."
+ (let* ((file-name (ada-xref-current-project-file no-user-question)))
+ (assoc file-name ada-xref-project-files)))
+
+(defun ada-show-current-project ()
+ "Display current project file name in message buffer."
+ (interactive)
+ (message (ada-xref-current-project-file)))
+
+(defun ada-show-current-main ()
+ "Display current main unit name in message buffer."
+ (interactive)
+ (message "ada-mode main_unit: %s" (ada-xref-get-project-field 'main_unit)))
+