Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

functions-with-overly-long-names

Name: Anonymous 2010-05-03 19:10

ITT we create a list of functions/class/modules/etc with long and verbose names. The minimum length allowed is 25 characters

From the R6RS:
make-custom-textual-input/output-port
call-with-bytevector-output-port
make-i/o-file-does-not-exist-error
bytevector-ieee-double-native-set!
port-has-set-port-position!?

Name: Anonymous 2010-05-03 19:15

!?
lol'd

Name: Anonymous 2010-05-03 20:30

getPreferredConfiguration static method of the SimpleUniverse class, from the API for Java3D.
Even better gems from Java3D are the getRightManualEyeInImagePlate and getPixelLocationInImagePlate from the Canvas3D class.

What? an non-basic API doesn't count?  then there's always setFocusTraversalKeysEnabled from the basic AWT libraries.

Name: Anonymous 2010-05-03 21:47

>>2
Performs a side effect and returns a Bool?

Name: Anonymous 2010-05-03 22:47

>>4
Sorry for not knowing the naming conventions in your toy language.

Name: Anonymous 2010-05-03 23:34

Here's my attempt at inspecting common function lengths in CL, and the results:

(defmacro with-gensyms (syms &body body)
  `(let ,(mapcar #'(lambda (x) `(,x (gensym ,(string x)))) syms)
     ,@body))

(defmacro get-symbols-list (kind &optional package) 
  (with-gensyms (symbol result)
    `(let (,result)     
       (,(ecase kind
                (:all 'do-all-symbols)
                (:any 'do-symbols)
                (:external 'do-external-symbols))
         (,symbol ,@(if (eql kind :all) nil `(,package))
                  (nreverse ,result))
         (push ,symbol ,result)))))

(defun get-all-external-symbols ()   
  (mapcan #'(lambda (x) (get-symbols-list :external x))
          (list-all-packages)))

(defun sort-symbols-by-name-length (syms)
  (sort (copy-list syms) #'> :key #'(lambda (x) (length (symbol-name x)))))

(defun list-name-length-sorted-symbols
    (&key
     (amount nil amount-present-p)
     (external-only nil)
     (functions-only nil)
     (package nil package-present-p))
  (when package-present-p
    (setq package (find-package package)))
  (let* ((fun-names
          (sort-symbols-by-name-length
            (if package-present-p
                (if external-only
                    (get-symbols-list :external package)
                    (get-symbols-list :any package))
                (if external-only                          
                    (get-all-external-symbols)                      
                    (get-symbols-list :all)))))
         (fun-names
          (if functions-only
              (remove-if (complement #'fboundp) fun-names)
              fun-names)))
    (if amount-present-p
        (subseq fun-names 0 amount)
        fun-names)))

(defun print-list (list)
  (mapcar #'print list))

;;; Here's the result for standard CL functions:
(print-list
 (remove-if
  #'(lambda (symbol)
      (<= (length (symbol-name symbol)) 25))
  (list-name-length-sorted-symbols  
   :external-only t
   :functions-only t
   :package :cl)))
=> prints
; 35 chars is the longest
UPDATE-INSTANCE-FOR-REDEFINED-CLASS
UPDATE-INSTANCE-FOR-DIFFERENT-CLASS
LOAD-LOGICAL-PATHNAME-TRANSLATIONS
SIMPLE-CONDITION-FORMAT-ARGUMENTS
SIMPLE-CONDITION-FORMAT-CONTROL
PPRINT-EXIT-IF-LIST-EXHAUSTED
LOGICAL-PATHNAME-TRANSLATIONS
MAKE-DISPATCH-MACRO-CHARACTER
GET-DISPATCH-MACRO-CHARACTER
SET-DISPATCH-MACRO-CHARACTER
INVOKE-RESTART-INTERACTIVELY
TWO-WAY-STREAM-OUTPUT-STREAM
TWO-WAY-STREAM-INPUT-STREAM
LISP-IMPLEMENTATION-VERSION
MAKE-LOAD-FORM-SAVING-SLOTS
CONCATENATED-STREAM-STREAMS
HASH-TABLE-REHASH-THRESHOLD
UPGRADED-ARRAY-ELEMENT-TYPE
FUNCTION-LAMBDA-EXPRESSION
READ-PRESERVING-WHITESPACE
COMPUTE-APPLICABLE-METHODS
ARITHMETIC-ERROR-OPERATION
UPGRADED-COMPLEX-PART-TYPE
TRANSLATE-LOGICAL-PATHNAME


;;; Now let's see all-times longest name within the internals/loaded packages:
(print-list (list-name-length-sorted-symbols :amount 100))
=> prints
SB-VM::|CACHED-FUN--MOV[(X66-SIMPLE-DIR ((OP 40) (IMM NIL TYPE 'IMM-ADDR)) (BACKQ-LIST 'NAME 'TAB (SWAP-IF 'DIR 'ACCUM ,  '([ IMM ]))))]-X66-SIMPLE-DIR-PREFILTER|
SB-VM::|CACHED-FUN--MOV[(X66-SIMPLE-DIR ((OP 40) (IMM NIL TYPE 'IMM-ADDR)) (BACKQ-LIST 'NAME 'TAB (SWAP-IF 'DIR 'ACCUM ,  '([ IMM ]))))]-X66-SIMPLE-DIR-PRINTER|
SB-VM::|CACHED-FUN--BT[(X66-EXT-REG/MEM-IMM ((OP (93 4)) (REG/MEM NIL TYPE WORD-REG/MEM) (IMM NIL TYPE IMM-DATA) (WIDTH 0)))]-X66-EXT-REG/MEM-IMM-PREFILTER|
;;; ...removed a lot of the same here...
SB-VM::|CACHED-FUN--ADD[(X66-ACCUM-IMM ((OP 2)))]-X66-ACCUM-IMM-PREFILTER|
SB-PCL::MAKE-OPTIMIZED-STRUCTURE-SLOT-BOUNDP-USING-CLASS-METHOD-FUNCTION
SB-PCL::MAKE-OPTIMIZED-STRUCTURE-SLOT-VALUE-USING-CLASS-METHOD-FUNCTION
SB-VM::|CACHED-FUN--PUSH[(REG-NO-WIDTH ((OP 10)))]-REG-NO-WIDTH-PRINTER|
SB-VM::|CACHED-FUN--ADD[(X66-ACCUM-IMM ((OP 2)))]-X66-ACCUM-IMM-PRINTER|
SB-PCL::MAKE-OPTIMIZED-STD-SETF-SLOT-VALUE-USING-CLASS-METHOD-FUNCTION
GET-ALL-SYMBOLS-WITH-A-FUNCTIONAL-VALUE-SORTED-BY-NAME-LENGTH
SB-IMPL::SIMPLE-CHARACTER-STRING-REPLACE-FROM-SIMPLE-CHARACTER-STRING*
SB-VM::|CACHED-FUN--XCHG[(REG-REG/MEM ((OP 67)))]-REG-REG/MEM-PRINTER|
SB-VM::DATA-VECTOR-REF-WITH-OFFSET/SIMPLE-ARRAY-COMPLEX-SINGLE-FLOAT
SB-VM::|CACHED-FUN--CMOV[(X66-COND-MOVE NIL)]-X66-COND-MOVE-PREFILTER|
SB-VM::DATA-VECTOR-SET-WITH-OFFSET/SIMPLE-ARRAY-COMPLEX-SINGLE-FLOAT
SB-VM::DATA-VECTOR-REF-WITH-OFFSET/SIMPLE-ARRAY-COMPLEX-DOUBLE-FLOAT
SB-VM::DATA-VECTOR-SET-WITH-OFFSET/SIMPLE-ARRAY-COMPLEX-DOUBLE-FLOAT
SB-VM::|CACHED-FUN--CALL[(NEAR-JUMP ((OP 232)))]-NEAR-JUMP-PREFILTER|
SB-VM::IMPL-OF-VM-SUPPORT-ROUTINE-MAKE-NLX-ENTRY-ARG-START-LOCATION
SB-VM::|CACHED-FUN--CMPS[(STRING-OP ((OP 83)))]-STRING-OP-PREFILTER|
SB-VM::|CACHED-FUN--CMOV[(X66-COND-MOVE NIL)]-X66-COND-MOVE-PRINTER|
SB-VM::IMPL-OF-VM-SUPPORT-ROUTINE-COMBINATION-IMPLEMENTATION-STYLE
SB-PCL::MAKE-OPTIMIZED-STD-SLOT-BOUNDP-USING-CLASS-METHOD-FUNCTION
SB-KERNEL::OBJECT-NOT-SIMPLE-ARRAY-COMPLEX-SINGLE-FLOAT-ERROR-HANDLER
SB-KERNEL::OBJECT-NOT-SIMPLE-ARRAY-COMPLEX-DOUBLE-FLOAT-ERROR-HANDLER
SB-KERNEL:REDEFINITION-REPLACES-COMPILED-FUNCTION-WITH-INTERPRETED-P
SB-VM::|CACHED-FUN--CALL[(NEAR-JUMP ((OP 232)))]-NEAR-JUMP-PRINTER|
SB-VM::|CACHED-FUN--JMP[(SHORT-JUMP ((OP 11)))]-SHORT-JUMP-PRINTER|
SB-VM::DATA-VECTOR-REF-C-WITH-OFFSET/SIMPLE-ARRAY-UNSIGNED-BYTE-4
SB-VM::DATA-VECTOR-REF-C-WITH-OFFSET/SIMPLE-ARRAY-UNSIGNED-BYTE-2

(print-list (list-name-length-sorted-symbols :external-only t :functions-only t :amount 50))
=> prints
SB-KERNEL:REDEFINITION-REPLACES-COMPILED-FUNCTION-WITH-INTERPRETED-P
SB-C:VM-SUPPORT-ROUTINES-MAKE-NLX-ENTRY-ARG-START-LOCATION
SB-C:VM-SUPPORT-ROUTINES-MAKE-RETURN-PC-PASSING-LOCATION
SB-C:VM-SUPPORT-ROUTINES-MAKE-UNKNOWN-VALUES-LOCATIONS
SB-C:VM-SUPPORT-ROUTINES-MAKE-RETURN-PC-SAVE-LOCATION
SB-C:VM-SUPPORT-ROUTINES-MAKE-OLD-FP-PASSING-LOCATION
SB-C:VM-SUPPORT-ROUTINES-MAKE-NUMBER-STACK-POINTER-TN
SB-C:DEFINITION-SOURCE-LOCATION-TOPLEVEL-FORM-NUMBER
SB-KERNEL:%MAKE-FUNCALLABLE-STRUCTURE-INSTANCE-ALLOCATOR
SB-KERNEL:UNINTERESTING-ORDINARY-FUNCTION-REDEFINITION-P
SB-C:VM-SUPPORT-ROUTINES-MAKE-OLD-FP-SAVE-LOCATION
SB-KERNEL:UNINTERESTING-GENERIC-FUNCTION-REDEFINITION-P
SB-C:VM-SUPPORT-ROUTINES-GENERATE-RETURN-SEQUENCE
SB-C:VM-SUPPORT-ROUTINES-MAKE-ARG-COUNT-LOCATION
SB-C:VM-SUPPORT-ROUTINES-SELECT-COMPONENT-FORMAT
SB-KERNEL:PROGRAM-ASSERT-SYMBOL-HOME-PACKAGE-UNLOCKED
SB-MOP:GENERIC-FUNCTION-ARGUMENT-PRECEDENCE-ORDER
SB-MOP:GENERIC-FUNCTION-ARGUMENT-PRECEDENCE-ORDER
SB-C:VM-SUPPORT-ROUTINES-MAKE-DYNAMIC-STATE-TNS
SB-C:VM-SUPPORT-ROUTINES-GENERATE-CALL-SEQUENCE
SB-MOP:GENERIC-FUNCTION-ARGUMENT-PRECEDENCE-ORDER
SB-C:VM-SUPPORT-ROUTINES-IMMEDIATE-CONSTANT-SC
SB-C:VM-SUPPORT-ROUTINES-STANDARD-ARG-LOCATION
SB-C:VM-SUPPORT-ROUTINES-MAKE-STACK-POINTER-TN
SB-MOP:COMPUTE-APPLICABLE-METHODS-USING-CLASSES
SB-MOP:COMPUTE-APPLICABLE-METHODS-USING-CLASSES
SB-MOP:COMPUTE-APPLICABLE-METHODS-USING-CLASSES
SB-KERNEL:REDEFINITION-REPLACES-GENERIC-FUNCTION-P
SB-C:VM-SUPPORT-ROUTINES-LOCATION-PRINT-NAME
SB-DISASSEM:MAYBE-NOTE-NIL-INDEXED-SYMBOL-SLOT-REF
SB-KERNEL:DEFINED-FTYPE-MATCHES-DECLARED-FTYPE-P
SB-C:VM-SUPPORT-ROUTINES-MAKE-CALL-OUT-TNS
SB-C:VM-SUPPORT-ROUTINES-PRIMITIVE-TYPE-OF
SB-C:DEFINITION-SOURCE-LOCATION-NAMESTRING
SB-SYS:ENSURE-DYNAMIC-FOREIGN-SYMBOL-ADDRESS
SB-KERNEL:BUILT-IN-CLASSOID-DIRECT-SUPERCLASSES
SB-KERNEL:VECTOR-OF-CHECKED-LENGTH-GIVEN-LENGTH
SB-KERNEL:SEQUENCE-OF-CHECKED-LENGTH-GIVEN-TYPE
SWANK:LIST-ALL-SYSTEMS-IN-CENTRAL-REGISTRY
ASDF:PREFERENCE-FILE-FOR-SYSTEM/OPERATION
SB-EVAL:INTERPRETED-FUNCTION-SOURCE-LOCATION
SB-MOP:FUNCALLABLE-STANDARD-INSTANCE-ACCESS
SB-MOP:SPECIALIZER-DIRECT-GENERIC-FUNCTIONS
SB-MOP:FUNCALLABLE-STANDARD-INSTANCE-ACCESS
SB-MOP:SPECIALIZER-DIRECT-GENERIC-FUNCTIONS
SB-VM:DESCRIPTOR-VS-NON-DESCRIPTOR-STORAGE
SB-MOP:GENERIC-FUNCTION-METHOD-COMBINATION
SB-MOP:GENERIC-FUNCTION-METHOD-COMBINATION
SB-MOP:ENSURE-GENERIC-FUNCTION-USING-CLASS
SB-C:VM-SUPPORT-ROUTINES-LOCATION-NUMBER

;;; How about from the MOP:

(asdf:oos 'asdf:load-op :closer-mop)

(print-list (list-name-length-sorted-symbols :external-only t :package :closer-mop :amount 25))
=> prints
SB-MOP:GENERIC-FUNCTION-ARGUMENT-PRECEDENCE-ORDER
SB-MOP:COMPUTE-APPLICABLE-METHODS-USING-CLASSES
SB-MOP:FUNCALLABLE-STANDARD-INSTANCE-ACCESS
SB-MOP:SPECIALIZER-DIRECT-GENERIC-FUNCTIONS
SB-MOP:ENSURE-GENERIC-FUNCTION-USING-CLASS
SB-MOP:GENERIC-FUNCTION-METHOD-COMBINATION
SB-MOP:STANDARD-EFFECTIVE-SLOT-DEFINITION
SB-MOP:COMPUTE-EFFECTIVE-SLOT-DEFINITION
SB-MOP:SET-FUNCALLABLE-INSTANCE-FUNCTION
SB-MOP:COMPUTE-DISCRIMINATING-FUNCTION
SB-MOP:EFFECTIVE-SLOT-DEFINITION-CLASS
SB-MOP:ACCESSOR-METHOD-SLOT-DEFINITION
SB-MOP:STANDARD-DIRECT-SLOT-DEFINITION
SB-MOP:CLASS-DIRECT-DEFAULT-INITARGS
SB-MOP:COMPUTE-CLASS-PRECEDENCE-LIST
SB-MOP:GENERIC-FUNCTION-METHOD-CLASS
SB-MOP:GENERIC-FUNCTION-DECLARATIONS
SB-MOP:GENERIC-FUNCTION-LAMBDA-LIST
SB-MOP:DIRECT-SLOT-DEFINITION-CLASS
SB-MOP:SLOT-DEFINITION-INITFUNCTION
SB-MOP:FUNCALLABLE-STANDARD-OBJECT
SB-MOP:SLOT-MAKUNBOUND-USING-CLASS
SB-MOP:SLOT-DEFINITION-ALLOCATION
SB-MOP:SPECIALIZER-DIRECT-METHODS
SB-MOP:FUNCALLABLE-STANDARD-CLASS


>>5
Back to /pr/ please!
>>2,4
I found it a bit strange that a predicate would be sideeffecting actually, but it does make sense if you're dealing with some remote stream of some sort, or maybe quantuum mechanics...

Name: >>6 2010-05-03 23:43

Seems I forgot to add some remove-duplicates in there.

Name: Anonymous 2010-05-04 3:25

>>5
Then sit down, shut up, and wait for R6RS-san to come up with an answer.

Name: Anonymous 2010-05-04 4:01

FYI, this thread crashes Konqueror.

Name: Anonymous 2010-05-04 6:22

>>5
Actually, it's a predicate for telling whether or not a port allows the set-port-position! function. In custom ports support for that,port-position and close-port[1]) is optional. Binary ports support all these methods, but whether or not Textual ports do is both implementation, and possibly transcoder dependant.


[sub]--
1. Of course, it would be annoying if you couldn't close custom ports. The close-port argument to make-custom-(binary|textual)-(input|output|input/output)-port is just a procedure to do any necessary cleanup. If close-port isn't provided, you get a default one.

Name: Anonymous 2010-05-04 6:51

>>9
what doesn't crash konqueror? every single crash-related bug in their shitty bugzilla ends up CLOSED WONTFIX.

Name: Anonymous 2010-05-04 8:37

>>11
This thread, for one. I don't know what >>9 is on about, but the buggy JS web-bugs embedded on world4ch do not actually cause konqueror to crash.

Name: Anonymous 2010-05-04 9:22

>>12
Konqueror 3.5.9 on Debian Lenny.

Name: Anonymous 2010-05-04 9:34

>>13
you should use www.opera.com

Name: Anonymous 2010-05-04 14:33

>>13
OHHHHHHHH

my god, why are you still using that? If you have any half-respectable sort of GPU, KDE4 runs a lot better than KDE3.

Name: Anonymous 2010-05-04 14:52

>>15
Hahahaha. Hardware graphics for window managers.

Name: Anonymous 2010-05-04 15:33

>>6
Back to /pr/ please!
Hey bro, don't be hatin'.

Name: Anonymous 2010-05-04 15:47

>>16
Enjoy your tearing while scrolling text, and watching the hideous repainting when a window becomes visible.

Name: Anonymous 2010-05-04 15:51

>>18
Wow, KDE3 and Qt really must be shit.


_____
Posted from my EEE 900 using Sawfish WM and Gtk+

Name: Anonymous 2010-05-04 16:00

>>19
Really. I haven't seen any such "tearing" nonsense, ever. And the last time I could actually watch a window repaint was when I decided it'd be fun to run X11 over a 28.8 modem connection.

Stupid KDE users.

Name: Anonymous 2010-05-04 16:13

>>20
I haven't seen any such "tearing" nonsense, ever.
Considering it's basically unavoidable¹ without hardware composition, I'd say you're just blind, or have never used a system that does it properly and therefore don't even notice something is wrong.

And the last time I could actually watch a window repaint
It annoys me on a i7-960, looks like your idea of complex application is a terminal emulator, or you're just that insensitive.

¹It can be done but it's prohibitively expensive. In general, it's never done.

Name: Anonymous 2010-05-04 16:37

>>21
never used a system that does it properly
Tearing is indeed a hard thing to do properly.

Switching between desktops, I can see that last.fm - a (graphically) relatively simple Qt application - takes about a tenth of a second to repaint its 1/4 screen-sized window; switching back to Firefox (maximised) is pretty much instantaneous.

Name: >>15 2010-05-04 17:42

>>16,18-22
Okay guys, knock it off. Seriously. I made my comment because it's not immediately obvious that KDE4 now outperforms KDE3 on modern (ca. 2004 I guess) hardware. (When it was first released it surely did not.) And that's all I wanted to say.

Name: Anonymous 2010-05-04 18:01

>>23
ill knock you're anus anytime, fagget.<

Name: Anonymous 2010-05-04 19:06

HAX MY DESKTOP ENVIRONMENT

Name: Anonymous 2010-05-05 1:02

>>25
CAN'T, I'M USING TWM

Name: Anonymous 2010-05-05 3:26

>>26
THE STANDARD

Name: Anonymous 2010-05-05 4:36

>>27
STANDARIZE MY ANUS

Name: Anonymous 2010-05-05 5:02

>>28
Okay. *grabs dick*

Name: Anonymous 2010-05-05 5:32

>>1 has obviously never wrote a GTK+ application.

Name: Anonymous 2010-05-05 8:21

Name: Anonymous 2011-01-31 20:08

<-- check em dubz

Name: Anonymous 2011-02-04 13:49


Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List